<!-- HTML header for doxygen 1.8.13-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>MTB CAT1 Peripheral driver library: Functions</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen_style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><a href="http://www.cypress.com/"><img alt="Logo" src="IFXCYP_one-line.png"/></a></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">MTB CAT1 Peripheral driver library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('group__group__sysanalog__functions.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#groups">API Reference</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">Functions<div class="ingroups"><a class="el" href="group__group__sysanalog.html">SysAnalog    (System Analog Reference Block)</a></div></div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">General Description</h2>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="groups"></a>
API Reference</h2></td></tr>
<tr class="memitem:group__group__sysanalog__functions__lposc"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions__lposc.html">Low Power Oscillator Functions</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:group__group__sysanalog__functions__timer"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions__timer.html">Timer Functions</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:gacef4e5ae550518abd0004e46e5ec4d64"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__sysanalog__enums.html#ga31d179a49097fe5a8b2e8863adba59f4">cy_en_sysanalog_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#gacef4e5ae550518abd0004e46e5ec4d64">Cy_SysAnalog_Init</a> (const <a class="el" href="structcy__stc__sysanalog__config__t.html">cy_stc_sysanalog_config_t</a> *config)</td></tr>
<tr class="memdesc:gacef4e5ae550518abd0004e46e5ec4d64"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initialize the AREF block.  <a href="#gacef4e5ae550518abd0004e46e5ec4d64">More...</a><br /></td></tr>
<tr class="separator:gacef4e5ae550518abd0004e46e5ec4d64"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga4deff86120f5e28e8789422797c42762"><td class="memItemLeft" align="right" valign="top">__STATIC_INLINE void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#ga4deff86120f5e28e8789422797c42762">Cy_SysAnalog_DeInit</a> (void)</td></tr>
<tr class="memdesc:ga4deff86120f5e28e8789422797c42762"><td class="mdescLeft">&#160;</td><td class="mdescRight">Reset AREF configuration back to power on reset defaults.  <a href="#ga4deff86120f5e28e8789422797c42762">More...</a><br /></td></tr>
<tr class="separator:ga4deff86120f5e28e8789422797c42762"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga3f48f2c07deed100d8c945dfc9a850a9"><td class="memItemLeft" align="right" valign="top">__STATIC_INLINE uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#ga3f48f2c07deed100d8c945dfc9a850a9">Cy_SysAnalog_GetIntrCauseExtended</a> (const PASS_Type *base)</td></tr>
<tr class="memdesc:ga3f48f2c07deed100d8c945dfc9a850a9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the PASS interrupt cause register value.  <a href="#ga3f48f2c07deed100d8c945dfc9a850a9">More...</a><br /></td></tr>
<tr class="separator:ga3f48f2c07deed100d8c945dfc9a850a9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga5d6d537beaf82fddf8e06f30b1d308b3"><td class="memItemLeft" align="right" valign="top">__STATIC_INLINE void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#ga5d6d537beaf82fddf8e06f30b1d308b3">Cy_SysAnalog_SetDeepSleepMode</a> (<a class="el" href="group__group__sysanalog__enums.html#ga0aadb061d882d9a964dff3729322cf12">cy_en_sysanalog_deep_sleep_t</a> deepSleep)</td></tr>
<tr class="memdesc:ga5d6d537beaf82fddf8e06f30b1d308b3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set what parts of the AREF are enabled in Deep Sleep mode.  <a href="#ga5d6d537beaf82fddf8e06f30b1d308b3">More...</a><br /></td></tr>
<tr class="separator:ga5d6d537beaf82fddf8e06f30b1d308b3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac0e2bee9d45ed5812d8a45a99979686d"><td class="memItemLeft" align="right" valign="top">__STATIC_INLINE <a class="el" href="group__group__sysanalog__enums.html#ga0aadb061d882d9a964dff3729322cf12">cy_en_sysanalog_deep_sleep_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#gac0e2bee9d45ed5812d8a45a99979686d">Cy_SysAnalog_GetDeepSleepMode</a> (void)</td></tr>
<tr class="memdesc:gac0e2bee9d45ed5812d8a45a99979686d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return Deep Sleep mode configuration as set by <a class="el" href="group__group__sysanalog__functions.html#ga5d6d537beaf82fddf8e06f30b1d308b3">Cy_SysAnalog_SetDeepSleepMode</a>.  <a href="#gac0e2bee9d45ed5812d8a45a99979686d">More...</a><br /></td></tr>
<tr class="separator:gac0e2bee9d45ed5812d8a45a99979686d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga153249c7b4cea72ee334ae877a211169"><td class="memItemLeft" align="right" valign="top">__STATIC_INLINE void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#ga153249c7b4cea72ee334ae877a211169">Cy_SysAnalog_Enable</a> (void)</td></tr>
<tr class="memdesc:ga153249c7b4cea72ee334ae877a211169"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enable the AREF hardware block.  <a href="#ga153249c7b4cea72ee334ae877a211169">More...</a><br /></td></tr>
<tr class="separator:ga153249c7b4cea72ee334ae877a211169"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaa50787f58138e1f55206988a5db124ae"><td class="memItemLeft" align="right" valign="top">__STATIC_INLINE void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#gaa50787f58138e1f55206988a5db124ae">Cy_SysAnalog_Disable</a> (void)</td></tr>
<tr class="memdesc:gaa50787f58138e1f55206988a5db124ae"><td class="mdescLeft">&#160;</td><td class="mdescRight">Disable the AREF hardware block.  <a href="#gaa50787f58138e1f55206988a5db124ae">More...</a><br /></td></tr>
<tr class="separator:gaa50787f58138e1f55206988a5db124ae"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga33f3a7cbdba876ae95c89c5a49bc0abb"><td class="memItemLeft" align="right" valign="top">__STATIC_INLINE void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#ga33f3a7cbdba876ae95c89c5a49bc0abb">Cy_SysAnalog_VrefSelect</a> (<a class="el" href="group__group__sysanalog__enums.html#ga953d5952135c077f6de135e058222459">cy_en_sysanalog_vref_source_t</a> vref)</td></tr>
<tr class="memdesc:ga33f3a7cbdba876ae95c89c5a49bc0abb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the source for the Vref.  <a href="#ga33f3a7cbdba876ae95c89c5a49bc0abb">More...</a><br /></td></tr>
<tr class="separator:ga33f3a7cbdba876ae95c89c5a49bc0abb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga7cb2b66d4b31d17a3e041dacd4fd9e6c"><td class="memItemLeft" align="right" valign="top">__STATIC_INLINE void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#ga7cb2b66d4b31d17a3e041dacd4fd9e6c">Cy_SysAnalog_IztatSelect</a> (<a class="el" href="group__group__sysanalog__enums.html#ga745102c8162e8d67ae113184c8ced99b">cy_en_sysanalog_iztat_source_t</a> iztat)</td></tr>
<tr class="memdesc:ga7cb2b66d4b31d17a3e041dacd4fd9e6c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the source for the 1 uA IZTAT.  <a href="#ga7cb2b66d4b31d17a3e041dacd4fd9e6c">More...</a><br /></td></tr>
<tr class="separator:ga7cb2b66d4b31d17a3e041dacd4fd9e6c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac8a45068447851d1617d8c9885907fc4"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__sysanalog__enums.html#ga31d179a49097fe5a8b2e8863adba59f4">cy_en_sysanalog_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__sysanalog__functions.html#gac8a45068447851d1617d8c9885907fc4">Cy_SysAnalog_DeepSleepInit</a> (PASS_Type *base, const <a class="el" href="structcy__stc__sysanalog__deep__sleep__config__t.html">cy_stc_sysanalog_deep_sleep_config_t</a> *config)</td></tr>
<tr class="memdesc:gac8a45068447851d1617d8c9885907fc4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initialize PASS_ver2 Deep Sleep features such as Low Power Oscillator, Deep Sleep Clock, Timer.  <a href="#gac8a45068447851d1617d8c9885907fc4">More...</a><br /></td></tr>
<tr class="separator:gac8a45068447851d1617d8c9885907fc4"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Function Documentation</h2>
<a id="gacef4e5ae550518abd0004e46e5ec4d64"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gacef4e5ae550518abd0004e46e5ec4d64">&#9670;&nbsp;</a></span>Cy_SysAnalog_Init()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__sysanalog__enums.html#ga31d179a49097fe5a8b2e8863adba59f4">cy_en_sysanalog_status_t</a> Cy_SysAnalog_Init </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="structcy__stc__sysanalog__config__t.html">cy_stc_sysanalog_config_t</a> *&#160;</td>
          <td class="paramname"><em>config</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Initialize the AREF block. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">config</td><td>Pointer to structure containing configuration data. See <a class="el" href="structcy__stc__sysanalog__config__t.html">cy_stc_sysanalog_config_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li><a class="el" href="group__group__sysanalog__enums.html#gga31d179a49097fe5a8b2e8863adba59f4a3ce48673d93f32086ce3b8525c1d5581">CY_SYSANALOG_SUCCESS</a> : initialization complete</li>
<li><a class="el" href="group__group__sysanalog__enums.html#gga31d179a49097fe5a8b2e8863adba59f4a6cee019b293e163d881c959f4809b4a0">CY_SYSANALOG_BAD_PARAM</a> : input pointers are null, initialization incomplete</li>
</ul>
</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd></dd></dl>
<div class="fragment"><div class="line"></div><div class="line">    <span class="comment">/* Scenario: The AREF is a system wide resource; it is used by multiple blocks (SAR, CTDAC, CTB, and CSDv2).</span></div><div class="line"><span class="comment">     * If one of these blocks require one of the AREF reference outputs, the AREF must be enabled.</span></div><div class="line"><span class="comment">     * The AREF block is not meant to be used stand-alone. */</span></div><div class="line">    </div><div class="line">    <span class="comment">/* The Cy_SysAnalog_Fast_Local configuration is provided by the driver</span></div><div class="line"><span class="comment">     * to cover a majority of use cases. It is the recommended configuration</span></div><div class="line"><span class="comment">     * for analog performance; it configures the block for</span></div><div class="line"><span class="comment">     * fast startup and sources all references with its local generators. */</span></div><div class="line">    <a class="code" href="group__group__sysanalog__enums.html#ga31d179a49097fe5a8b2e8863adba59f4">cy_en_sysanalog_status_t</a> status;</div><div class="line">    status = <a class="code" href="group__group__sysanalog__functions.html#gacef4e5ae550518abd0004e46e5ec4d64">Cy_SysAnalog_Init</a>(&amp;<a class="code" href="group__group__sysanalog__globals.html#ga85e9e1cd8c1e6fe581043cbab3083017">Cy_SysAnalog_Fast_Local</a>);</div><div class="line">    </div><div class="line">    <span class="comment">/* Turn on the hardware block. */</span></div><div class="line">    <a class="code" href="group__group__sysanalog__functions.html#ga153249c7b4cea72ee334ae877a211169">Cy_SysAnalog_Enable</a>();</div><div class="line">    </div><div class="line">    <span class="comment">/* After the AREF is enabled, enable the consumer blocks (SAR, CTDAC, CTB, and CSDv2). */</span></div><div class="line">    </div></div><!-- fragment -->
</div>
</div>
<a id="ga4deff86120f5e28e8789422797c42762"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga4deff86120f5e28e8789422797c42762">&#9670;&nbsp;</a></span>Cy_SysAnalog_DeInit()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">__STATIC_INLINE void Cy_SysAnalog_DeInit </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Reset AREF configuration back to power on reset defaults. </p>
<dl class="section return"><dt>Returns</dt><dd>None</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd></dd></dl>
<div class="fragment"><div class="line">    <span class="comment">/* Scenario: The AREF is no longer needed. Reset the AREF to power on reset settings. */</span></div><div class="line"></div><div class="line">    (void) <a class="code" href="group__group__sysanalog__functions.html#ga4deff86120f5e28e8789422797c42762">Cy_SysAnalog_DeInit</a>();</div></div><!-- fragment -->
</div>
</div>
<a id="ga3f48f2c07deed100d8c945dfc9a850a9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga3f48f2c07deed100d8c945dfc9a850a9">&#9670;&nbsp;</a></span>Cy_SysAnalog_GetIntrCauseExtended()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">__STATIC_INLINE uint32_t Cy_SysAnalog_GetIntrCauseExtended </td>
          <td>(</td>
          <td class="paramtype">const PASS_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return the PASS interrupt cause register value. </p>
<p>Depending on the device, there may be interrupts from these PASS blocks:</p><ol type="1">
<li>CTDAC (up to 4 instances)</li>
<li>CTB(m) (up to 4 instances)</li>
<li>SAR (up to 4 instances)</li>
<li>FIFO (up to 4 instances)</li>
</ol>
<p>Compare this returned value with the enum values in <a class="el" href="group__group__sysanalog__enums.html#gaa031d15d64f0d87a749bc99b3e0dc083">cy_en_sysanalog_intr_cause_t</a> to determine which block caused/triggered the interrupt.</p>
<dl class="section return"><dt>Returns</dt><dd>uint32_t Interrupt cause register value.</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd></dd></dl>
<div class="fragment"><div class="line">    </div><div class="line">    <span class="comment">/* Scenario: The device has multiple CTBs or CTDACs and</span></div><div class="line"><span class="comment">     * that user wants to know which instance caused the global interrupt.</span></div><div class="line"><span class="comment">     * This function is not useful or needed when the device has only</span></div><div class="line"><span class="comment">     * one CTB or CTDAC. */</span></div><div class="line">    uint32_t intrCause;</div><div class="line">    intrCause = <a class="code" href="group__group__sysanalog__functions.html#ga3f48f2c07deed100d8c945dfc9a850a9">Cy_SysAnalog_GetIntrCauseExtended</a>(PASS);</div><div class="line">    </div><div class="line">    <span class="keywordflow">if</span> ((uint32_t) <a class="code" href="group__group__sysanalog__enums.html#ggaa031d15d64f0d87a749bc99b3e0dc083a0d9797ca47fee44f12d726b969344b06">CY_SYSANALOG_INTR_CAUSE_CTB0</a> == (intrCause &amp; (uint32_t) <a class="code" href="group__group__sysanalog__enums.html#ggaa031d15d64f0d87a749bc99b3e0dc083a0d9797ca47fee44f12d726b969344b06">CY_SYSANALOG_INTR_CAUSE_CTB0</a>))</div><div class="line">    {</div><div class="line">        <span class="comment">/* CTB0 caused the interrupt */</span></div><div class="line">    }</div></div><!-- fragment -->
</div>
</div>
<a id="ga5d6d537beaf82fddf8e06f30b1d308b3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga5d6d537beaf82fddf8e06f30b1d308b3">&#9670;&nbsp;</a></span>Cy_SysAnalog_SetDeepSleepMode()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">__STATIC_INLINE void Cy_SysAnalog_SetDeepSleepMode </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__sysanalog__enums.html#ga0aadb061d882d9a964dff3729322cf12">cy_en_sysanalog_deep_sleep_t</a>&#160;</td>
          <td class="paramname"><em>deepSleep</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Set what parts of the AREF are enabled in Deep Sleep mode. </p>
<ul>
<li>Disable AREF IP block</li>
<li>Enable IPTAT generator for fast wakeup from Deep Sleep mode. IPTAT outputs for CTBs are disabled.</li>
<li>Enable IPTAT generator and IPTAT outputs for CTB</li>
<li>Enable all generators and outputs: IPTAT, IZTAT, and VREF</li>
</ul>
<dl class="section note"><dt>Note</dt><dd>The SRSS references are not available to the AREF in Deep Sleep mode. When operating in Deep Sleep mode, the local or external references must be selected.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">deepSleep</td><td>Select a value from <a class="el" href="group__group__sysanalog__enums.html#ga0aadb061d882d9a964dff3729322cf12">cy_en_sysanalog_deep_sleep_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd></dd></dl>
<div class="fragment"><div class="line"></div><div class="line">    <span class="comment">/* Scenario:</span></div><div class="line"><span class="comment">     * The CTB opamps are using the current references from the AREF block.</span></div><div class="line"><span class="comment">     * The CTDAC is using the 1.2 V voltage reference from the AREF block.</span></div><div class="line"><span class="comment">     * The user wants the CTB and CTDAC to be enabled in Deep Sleep mode.</span></div><div class="line"><span class="comment">     * In order for the CTB and CTDAC to function in Deep Sleep mode, the references</span></div><div class="line"><span class="comment">     * from the AREF block must also be enabled for Deep Sleep operation. */</span></div><div class="line">    <a class="code" href="group__group__sysanalog__functions.html#ga5d6d537beaf82fddf8e06f30b1d308b3">Cy_SysAnalog_SetDeepSleepMode</a>(<a class="code" href="group__group__sysanalog__enums.html#gga0aadb061d882d9a964dff3729322cf12aaf8feaa23b7bbbdaba3981fa7e9a64de">CY_SYSANALOG_DEEPSLEEP_IPTAT_IZTAT_VREF</a>);</div><div class="line">    </div></div><!-- fragment -->
</div>
</div>
<a id="gac0e2bee9d45ed5812d8a45a99979686d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gac0e2bee9d45ed5812d8a45a99979686d">&#9670;&nbsp;</a></span>Cy_SysAnalog_GetDeepSleepMode()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">__STATIC_INLINE <a class="el" href="group__group__sysanalog__enums.html#ga0aadb061d882d9a964dff3729322cf12">cy_en_sysanalog_deep_sleep_t</a> Cy_SysAnalog_GetDeepSleepMode </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return Deep Sleep mode configuration as set by <a class="el" href="group__group__sysanalog__functions.html#ga5d6d537beaf82fddf8e06f30b1d308b3">Cy_SysAnalog_SetDeepSleepMode</a>. </p>
<dl class="section return"><dt>Returns</dt><dd>A value from <a class="el" href="group__group__sysanalog__enums.html#ga0aadb061d882d9a964dff3729322cf12">cy_en_sysanalog_deep_sleep_t</a></dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd></dd></dl>
<div class="fragment"><div class="line">    </div><div class="line">    <span class="comment">/* Scenario: As a system wide resource, the AREF Deep Sleep mode configuration</span></div><div class="line"><span class="comment">     * affects all consumer blocks. The Deep Sleep mode settings should be queried</span></div><div class="line"><span class="comment">     * before it is modified as to not affect other blocks. */</span></div><div class="line"></div><div class="line">    <a class="code" href="group__group__sysanalog__enums.html#ga0aadb061d882d9a964dff3729322cf12">cy_en_sysanalog_deep_sleep_t</a> <a class="code" href="group__group__ipc__bt__data__structures.html#ga37e90f5e3bd99fac2021fb3a326607d4">mode</a>;</div><div class="line">    mode = <a class="code" href="group__group__sysanalog__functions.html#gac0e2bee9d45ed5812d8a45a99979686d">Cy_SysAnalog_GetDeepSleepMode</a>();</div><div class="line">    </div><div class="line">    <span class="comment">/* Don&#39;t enable the voltage reference, VREF, in Deep Sleep unless</span></div><div class="line"><span class="comment">     * it is needed by other blocks (e.g. the CTDAC) as it will consume more power. */</span></div><div class="line">    <span class="keywordflow">if</span> (<a class="code" href="group__group__sysanalog__enums.html#gga0aadb061d882d9a964dff3729322cf12aaf8feaa23b7bbbdaba3981fa7e9a64de">CY_SYSANALOG_DEEPSLEEP_IPTAT_IZTAT_VREF</a> != mode)</div><div class="line">    {</div><div class="line">        <a class="code" href="group__group__sysanalog__functions.html#ga5d6d537beaf82fddf8e06f30b1d308b3">Cy_SysAnalog_SetDeepSleepMode</a>(<a class="code" href="group__group__sysanalog__enums.html#gga0aadb061d882d9a964dff3729322cf12ac3b1263aa8889f21a72a8ec9d21066b2">CY_SYSANALOG_DEEPSLEEP_IPTAT_2</a>);</div><div class="line">    }</div></div><!-- fragment -->
</div>
</div>
<a id="ga153249c7b4cea72ee334ae877a211169"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga153249c7b4cea72ee334ae877a211169">&#9670;&nbsp;</a></span>Cy_SysAnalog_Enable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">__STATIC_INLINE void Cy_SysAnalog_Enable </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Enable the AREF hardware block. </p>
<dl class="section return"><dt>Returns</dt><dd>None</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd></dd></dl>
<div class="fragment"><div class="line"></div><div class="line">    <span class="comment">/* Scenario: The AREF block has been initialized and needs to be enabled. */</span></div><div class="line">    <a class="code" href="group__group__sysanalog__functions.html#ga153249c7b4cea72ee334ae877a211169">Cy_SysAnalog_Enable</a>();</div><div class="line">    </div><div class="line">    <span class="comment">/* After the AREF is enabled, enable the consumer blocks (SAR, CTDAC, CTB, and CSDv2). */</span></div><div class="line">    </div></div><!-- fragment -->
</div>
</div>
<a id="gaa50787f58138e1f55206988a5db124ae"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaa50787f58138e1f55206988a5db124ae">&#9670;&nbsp;</a></span>Cy_SysAnalog_Disable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">__STATIC_INLINE void Cy_SysAnalog_Disable </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Disable the AREF hardware block. </p>
<dl class="section return"><dt>Returns</dt><dd>None</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd></dd></dl>
<div class="fragment"><div class="line"></div><div class="line">    <span class="comment">/* Scenario: The AREF block is no longer needed.</span></div><div class="line"><span class="comment">     * That is, all the consumer blocks (SAR, CTDAC, CTB, and CSDv2) have been disabled.</span></div><div class="line"><span class="comment">     * Disable the AREF block to save power. */</span></div><div class="line">    <a class="code" href="group__group__sysanalog__functions.html#gaa50787f58138e1f55206988a5db124ae">Cy_SysAnalog_Disable</a>();</div><div class="line"></div></div><!-- fragment -->
</div>
</div>
<a id="ga33f3a7cbdba876ae95c89c5a49bc0abb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga33f3a7cbdba876ae95c89c5a49bc0abb">&#9670;&nbsp;</a></span>Cy_SysAnalog_VrefSelect()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">__STATIC_INLINE void Cy_SysAnalog_VrefSelect </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__sysanalog__enums.html#ga953d5952135c077f6de135e058222459">cy_en_sysanalog_vref_source_t</a>&#160;</td>
          <td class="paramname"><em>vref</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Set the source for the Vref. </p>
<p>The Vref can come from:</p><ul>
<li>the locally generated 1.2 V reference</li>
<li>the SRSS, which provides a 0.8 V reference (not available to the AREF in Deep Sleep mode)</li>
<li>an external device pin</li>
</ul>
<p>The locally generated reference has higher accuracy, more stability over temperature, and lower noise than the SRSS reference.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">vref</td><td>Value from enum <a class="el" href="group__group__sysanalog__enums.html#ga953d5952135c077f6de135e058222459">cy_en_sysanalog_vref_source_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd></dd></dl>
<div class="fragment"><div class="line">    <span class="comment">/* Select the local 1.2 V generator as the Vref source for optimal analog performance. */</span></div><div class="line">    <a class="code" href="group__group__sysanalog__functions.html#ga33f3a7cbdba876ae95c89c5a49bc0abb">Cy_SysAnalog_VrefSelect</a>(<a class="code" href="group__group__sysanalog__enums.html#gga953d5952135c077f6de135e058222459a2487a839aa1c8244f65a684b319daa6b">CY_SYSANALOG_VREF_SOURCE_LOCAL_1_2V</a>);</div></div><!-- fragment -->
</div>
</div>
<a id="ga7cb2b66d4b31d17a3e041dacd4fd9e6c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga7cb2b66d4b31d17a3e041dacd4fd9e6c">&#9670;&nbsp;</a></span>Cy_SysAnalog_IztatSelect()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">__STATIC_INLINE void Cy_SysAnalog_IztatSelect </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__sysanalog__enums.html#ga745102c8162e8d67ae113184c8ced99b">cy_en_sysanalog_iztat_source_t</a>&#160;</td>
          <td class="paramname"><em>iztat</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Set the source for the 1 uA IZTAT. </p>
<p>The IZTAT can come from:</p><ul>
<li>the locally generated IZTAT</li>
<li>the SRSS (not available to the AREF in Deep Sleep mode)</li>
</ul>
<p>The locally generated reference has higher accuracy, more stability over temperature, and lower noise than the SRSS reference.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">iztat</td><td>Value from enum <a class="el" href="group__group__sysanalog__enums.html#ga745102c8162e8d67ae113184c8ced99b">cy_en_sysanalog_iztat_source_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd></dd></dl>
<div class="fragment"><div class="line">    <span class="comment">/* Select the local generator as the IZTAT source for optimal analog performance. */</span></div><div class="line">    <a class="code" href="group__group__sysanalog__functions.html#ga7cb2b66d4b31d17a3e041dacd4fd9e6c">Cy_SysAnalog_IztatSelect</a>(<a class="code" href="group__group__sysanalog__enums.html#gga745102c8162e8d67ae113184c8ced99ba3b4fc99af78704905e78fcae12dd4a06">CY_SYSANALOG_IZTAT_SOURCE_LOCAL</a>);</div></div><!-- fragment -->
</div>
</div>
<a id="gac8a45068447851d1617d8c9885907fc4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gac8a45068447851d1617d8c9885907fc4">&#9670;&nbsp;</a></span>Cy_SysAnalog_DeepSleepInit()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__sysanalog__enums.html#ga31d179a49097fe5a8b2e8863adba59f4">cy_en_sysanalog_status_t</a> Cy_SysAnalog_DeepSleepInit </td>
          <td>(</td>
          <td class="paramtype">PASS_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="structcy__stc__sysanalog__deep__sleep__config__t.html">cy_stc_sysanalog_deep_sleep_config_t</a> *&#160;</td>
          <td class="paramname"><em>config</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Initialize PASS_ver2 Deep Sleep features such as Low Power Oscillator, Deep Sleep Clock, Timer. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>Pointer to the PASS register structure.</td></tr>
    <tr><td class="paramname">config</td><td>Pointer to structure containing configuration data. See <a class="el" href="structcy__stc__sysanalog__deep__sleep__config__t.html">cy_stc_sysanalog_deep_sleep_config_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li><a class="el" href="group__group__sysanalog__enums.html#gga31d179a49097fe5a8b2e8863adba59f4a3ce48673d93f32086ce3b8525c1d5581">CY_SYSANALOG_SUCCESS</a> : initialization complete</li>
<li><a class="el" href="group__group__sysanalog__enums.html#gga31d179a49097fe5a8b2e8863adba59f4a6cee019b293e163d881c959f4809b4a0">CY_SYSANALOG_BAD_PARAM</a> : input pointers are null, initialization incomplete</li>
</ul>
</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"></div><div class="line">    <span class="comment">/* Initializes Deep Sleep features */</span></div><div class="line">    <span class="keyword">const</span> <a class="code" href="structcy__stc__sysanalog__deep__sleep__config__t.html">cy_stc_sysanalog_deep_sleep_config_t</a> dsConfig =</div><div class="line">    {</div><div class="line">        <span class="comment">/*.lpOscDsMode  */</span> <a class="code" href="group__group__sysanalog__enums.html#gga8d5d1c61a078ccf107fce8277b39a11ba055b5278d95fda347a979db2e8142874">CY_SYSANALOG_LPOSC_ALWAYS_ON</a>,</div><div class="line">        <span class="comment">/*.dsClkSource  */</span> <a class="code" href="group__group__sysanalog__enums.html#gga159a193656bc75a45b4603982958f88ca1ce12564833d4ba46ae1002636606f95">CY_SYSANALOG_DEEPSLEEP_SRC_LPOSC</a>,</div><div class="line">        <span class="comment">/*.dsClkdivider */</span> <a class="code" href="group__group__sysanalog__enums.html#ggafaf730c28e19936cce24c04d525e4c31acf90874d98cfb188109055e8dbcc371e">CY_SYSANALOG_DEEPSLEEP_CLK_DIV_BY_4</a>,</div><div class="line">        <span class="comment">/*.timerClock   */</span> <a class="code" href="group__group__sysanalog__enums.html#gga608d2bbfed03023ee844347f7c339f4ea4c248c2a2bc423c7b3795a96b5c05971">CY_SYSANALOG_TIMER_CLK_DEEPSLEEP</a>,</div><div class="line">        <span class="comment">/*.timerPeriod  */</span> 4000UL</div><div class="line">    };</div><div class="line">    </div><div class="line">    <span class="keywordflow">if</span> (<a class="code" href="group__group__sysanalog__enums.html#gga31d179a49097fe5a8b2e8863adba59f4a3ce48673d93f32086ce3b8525c1d5581">CY_SYSANALOG_SUCCESS</a> == <a class="code" href="group__group__sysanalog__functions.html#gac8a45068447851d1617d8c9885907fc4">Cy_SysAnalog_DeepSleepInit</a>(PASS, &amp;dsConfig))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Enable LpOsc and Timer blocks. */</span></div><div class="line">        <a class="code" href="group__group__sysanalog__functions__lposc.html#ga3d570989fa28e6a4e86ae51970930f6c">Cy_SysAnalog_LpOscEnable</a>(PASS);</div><div class="line">        <a class="code" href="group__group__sysanalog__functions__timer.html#gabf1f6993d098242c63769608a1e236f7">Cy_SysAnalog_TimerEnable</a>(PASS);</div><div class="line">    }</div></div><!-- fragment --></dd></dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part
<div id="nav-path" class="navpath">
    <ul>
        <li class="footer">
            Generated for <b>MTB CAT1 Peripheral driver library</b> by <b>Cypress Semiconductor Corporation</b>.
            All rights reserved.
        </li>
    </ul>
</div>
-->
</body>
</html>
